Optimal. Leaf size=117 \[ -\frac {2 b c^2+3 a d^2}{2 c^4 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}-\frac {\left (2 b c^2+3 a d^2\right ) \tan ^{-1}\left (\frac {\sqrt {-c+d x} \sqrt {c+d x}}{c}\right )}{2 c^5} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.07, antiderivative size = 117, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 31, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.161, Rules used = {465, 106, 21,
94, 211} \begin {gather*} -\frac {\left (3 a d^2+2 b c^2\right ) \text {ArcTan}\left (\frac {\sqrt {d x-c} \sqrt {c+d x}}{c}\right )}{2 c^5}-\frac {3 a d^2+2 b c^2}{2 c^4 \sqrt {d x-c} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {d x-c} \sqrt {c+d x}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 21
Rule 94
Rule 106
Rule 211
Rule 465
Rubi steps
\begin {align*} \int \frac {a+b x^2}{x^3 (-c+d x)^{3/2} (c+d x)^{3/2}} \, dx &=\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {1}{2} \left (2 b+\frac {3 a d^2}{c^2}\right ) \int \frac {1}{x (-c+d x)^{3/2} (c+d x)^{3/2}} \, dx\\ &=-\frac {2 b c^2+3 a d^2}{2 c^4 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {\left (-2 b-\frac {3 a d^2}{c^2}\right ) \int \frac {c d+d^2 x}{x \sqrt {-c+d x} (c+d x)^{3/2}} \, dx}{2 c^2 d}\\ &=-\frac {2 b c^2+3 a d^2}{2 c^4 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}-\frac {\left (2 b c^2+3 a d^2\right ) \int \frac {1}{x \sqrt {-c+d x} \sqrt {c+d x}} \, dx}{2 c^4}\\ &=-\frac {2 b c^2+3 a d^2}{2 c^4 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}-\frac {\left (d \left (2 b c^2+3 a d^2\right )\right ) \text {Subst}\left (\int \frac {1}{c^2 d+d x^2} \, dx,x,\sqrt {-c+d x} \sqrt {c+d x}\right )}{2 c^4}\\ &=-\frac {2 b c^2+3 a d^2}{2 c^4 \sqrt {-c+d x} \sqrt {c+d x}}+\frac {a}{2 c^2 x^2 \sqrt {-c+d x} \sqrt {c+d x}}-\frac {\left (2 b c^2+3 a d^2\right ) \tan ^{-1}\left (\frac {\sqrt {-c+d x} \sqrt {c+d x}}{c}\right )}{2 c^5}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.20, size = 93, normalized size = 0.79 \begin {gather*} \frac {\frac {-2 b c^3 x^2+a \left (c^3-3 c d^2 x^2\right )}{x^2 \sqrt {-c+d x} \sqrt {c+d x}}+\left (4 b c^2+6 a d^2\right ) \tan ^{-1}\left (\frac {\sqrt {c+d x}}{\sqrt {-c+d x}}\right )}{2 c^5} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(323\) vs.
\(2(99)=198\).
time = 0.34, size = 324, normalized size = 2.77
method | result | size |
default | \(\frac {\sqrt {d x -c}\, \left (-3 \ln \left (-\frac {2 \left (c^{2}-\sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}\right )}{x}\right ) a \,d^{4} x^{4}-2 \ln \left (-\frac {2 \left (c^{2}-\sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}\right )}{x}\right ) b \,c^{2} d^{2} x^{4}+3 \ln \left (-\frac {2 \left (c^{2}-\sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}\right )}{x}\right ) a \,c^{2} d^{2} x^{2}+2 \ln \left (-\frac {2 \left (c^{2}-\sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}\right )}{x}\right ) b \,c^{4} x^{2}+3 \sqrt {d^{2} x^{2}-c^{2}}\, \sqrt {-c^{2}}\, a \,d^{2} x^{2}+2 \sqrt {d^{2} x^{2}-c^{2}}\, \sqrt {-c^{2}}\, b \,c^{2} x^{2}-\sqrt {d^{2} x^{2}-c^{2}}\, \sqrt {-c^{2}}\, a \,c^{2}\right )}{2 c^{4} \sqrt {-c^{2}}\, x^{2} \left (-d x +c \right ) \sqrt {d^{2} x^{2}-c^{2}}\, \sqrt {d x +c}}\) | \(324\) |
risch | \(\frac {a \left (-d x +c \right ) \sqrt {d x +c}}{2 c^{4} x^{2} \sqrt {d x -c}}-\frac {\left (-\frac {d \sqrt {d^{2} \left (x +\frac {c}{d}\right )^{2}-2 c d \left (x +\frac {c}{d}\right )}\, a}{2 c^{5} \left (x +\frac {c}{d}\right )}-\frac {\sqrt {d^{2} \left (x +\frac {c}{d}\right )^{2}-2 c d \left (x +\frac {c}{d}\right )}\, b}{2 c^{3} d \left (x +\frac {c}{d}\right )}+\frac {d \sqrt {d^{2} \left (x -\frac {c}{d}\right )^{2}+2 c d \left (x -\frac {c}{d}\right )}\, a}{2 c^{5} \left (x -\frac {c}{d}\right )}+\frac {\sqrt {d^{2} \left (x -\frac {c}{d}\right )^{2}+2 c d \left (x -\frac {c}{d}\right )}\, b}{2 c^{3} d \left (x -\frac {c}{d}\right )}-\frac {3 \ln \left (\frac {-2 c^{2}+2 \sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}}{x}\right ) a \,d^{2}}{2 c^{4} \sqrt {-c^{2}}}-\frac {\ln \left (\frac {-2 c^{2}+2 \sqrt {-c^{2}}\, \sqrt {d^{2} x^{2}-c^{2}}}{x}\right ) b}{c^{2} \sqrt {-c^{2}}}\right ) \sqrt {\left (d x -c \right ) \left (d x +c \right )}}{\sqrt {d x -c}\, \sqrt {d x +c}}\) | \(348\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.50, size = 104, normalized size = 0.89 \begin {gather*} \frac {b \arcsin \left (\frac {c}{d {\left | x \right |}}\right )}{c^{3}} + \frac {3 \, a d^{2} \arcsin \left (\frac {c}{d {\left | x \right |}}\right )}{2 \, c^{5}} - \frac {b}{\sqrt {d^{2} x^{2} - c^{2}} c^{2}} - \frac {3 \, a d^{2}}{2 \, \sqrt {d^{2} x^{2} - c^{2}} c^{4}} + \frac {a}{2 \, \sqrt {d^{2} x^{2} - c^{2}} c^{2} x^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 4.14, size = 138, normalized size = 1.18 \begin {gather*} \frac {{\left (a c^{3} - {\left (2 \, b c^{3} + 3 \, a c d^{2}\right )} x^{2}\right )} \sqrt {d x + c} \sqrt {d x - c} - 2 \, {\left ({\left (2 \, b c^{2} d^{2} + 3 \, a d^{4}\right )} x^{4} - {\left (2 \, b c^{4} + 3 \, a c^{2} d^{2}\right )} x^{2}\right )} \arctan \left (-\frac {d x - \sqrt {d x + c} \sqrt {d x - c}}{c}\right )}{2 \, {\left (c^{5} d^{2} x^{4} - c^{7} x^{2}\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 211 vs.
\(2 (99) = 198\).
time = 0.71, size = 211, normalized size = 1.80 \begin {gather*} \frac {{\left (2 \, b c^{2} + 3 \, a d^{2}\right )} \arctan \left (\frac {{\left (\sqrt {d x + c} - \sqrt {d x - c}\right )}^{2}}{2 \, c}\right )}{c^{5}} - \frac {{\left (b c^{2} + a d^{2}\right )} \sqrt {d x + c}}{2 \, \sqrt {d x - c} c^{5}} + \frac {2 \, {\left (b c^{2} + a d^{2}\right )}}{{\left ({\left (\sqrt {d x + c} - \sqrt {d x - c}\right )}^{2} + 2 \, c\right )} c^{4}} + \frac {2 \, {\left (a d^{2} {\left (\sqrt {d x + c} - \sqrt {d x - c}\right )}^{6} - 4 \, a c^{2} d^{2} {\left (\sqrt {d x + c} - \sqrt {d x - c}\right )}^{2}\right )}}{{\left ({\left (\sqrt {d x + c} - \sqrt {d x - c}\right )}^{4} + 4 \, c^{2}\right )}^{2} c^{4}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {b\,x^2+a}{x^3\,{\left (c+d\,x\right )}^{3/2}\,{\left (d\,x-c\right )}^{3/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________